package com.base.system.mybatisPlus.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 用户信息表
 * </p>
 *
 * @author 木木
 * @since 2020-04-19
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("user")
public class MybatisUser extends Model<MybatisUser> {

    private static final long serialVersionUID = 1L;

    /**
     * 主键，自动生成
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    private String createBy;

    private LocalDateTime createTime;

    private LocalDateTime lastUpateTime;

    private String updateBy;

    /**
     * 头像
     */
    private String actor;

    /**
     * 年龄
     */
    private Integer age;

    /**
     * 邮箱
     */
    private String email;

    /**
     * 身份证
     */
    private String idNumber;

    /**
     * 昵称
     */
    private String nickName;

    /**
     * 联系电话
     */
    private String phone;

    /**
     * 真实姓名
     */
    private String realName;

    /**
     * 性别
     */
    private String sex;

    /**
     * 用户状态
     */
    private Integer state;

    /**
     * 账号
     */
    private String userAcount;


    @Override
    protected Serializable pkVal() {
        return id;
    }

}
